<<<<<<< HEAD
name

import time

from selenium import webdriver
from selenium.webdriver.common.by import By

driver = webdriver.Chrome()
driver.implicitly_wait(10)
driver.maximize_window()
#移库登记增删改查
def login():
    #输入地址
    driver.get('http://10.10.10.120:30209')
    #输入账号密码
    driver.find_element(By.ID,'username').send_keys('administrator')
    driver.find_element(By.ID,'password').send_keys('Gdjt@2021')
    driver.find_element(By.XPATH,'//button').click()
    time.sleep(5)
    #进入移库登记
    driver.find_element(By.XPATH,'//*[text()="移库管理"]').click()
    driver.find_element(By.XPATH, '//*[text()="移库登记"]').click()
    #添 加
    driver.find_element(By.XPATH, '//*[text()="添 加"]/..').click()
    time.sleep(3)
    # 请选择来源仓库
    driver.find_element(By.XPATH, '//*[text()="请选择来源仓库"]').click()
    time.sleep(3)
    driver.find_element(By.XPATH, '//li[text()="永春库"]').click()
    # 请选择目标仓库
    driver.find_element(By.XPATH, '//*[text()="请选择目标仓库"]').click()
    time.sleep(3)
    driver.find_element(By.XPATH, '(//li[text()="西湖库"])[2]').click()
    #添 加
    driver.find_element(By.XPATH, '//*[text()="保 存"]/..').click()
    time.sleep(2)
    num = driver.find_element(By.XPATH,'//div[text()="移库单号"]/following-sibling::div[1]').text
    driver.find_element(By.XPATH,'//button[@aria-label="Close"]').click()
   #搜索单号
    driver.find_element(By.XPATH,'//input[@placeholder="请搜索移库单号/物料名称/物料编码"]').send_keys(num)
    driver.find_element(By.XPATH,'//*[text()="搜 索"]/..').click()
    time.sleep(3)
    #删除单号
    driver.find_element(By.XPATH, '//*[text()="操作"]/..').click()
    driver.find_element(By.XPATH, '//*[text()="删除"]/..').click()
    driver.find_element(By.XPATH, '//*[text()="确 定"]/..').click()

if __name__ == '__main__':
    login()
=======
name

import time

from selenium import webdriver
from selenium.webdriver.common.by import By

driver = webdriver.Chrome()
driver.implicitly_wait(10)
driver.maximize_window()
#移库登记增删改查
def login():
    #输入地址
    driver.get('http://10.10.10.120:30209')
    #输入账号密码
    driver.find_element(By.ID,'username').send_keys('administrator')
    driver.find_element(By.ID,'password').send_keys('Gdjt@2021')
    driver.find_element(By.XPATH,'//button').click()
    time.sleep(5)
    #进入移库登记
    driver.find_element(By.XPATH,'//*[text()="移库管理"]').click()
    driver.find_element(By.XPATH, '//*[text()="移库登记"]').click()
    #添 加
    driver.find_element(By.XPATH, '//*[text()="添 加"]/..').click()
    time.sleep(3)
    # 请选择来源仓库
    driver.find_element(By.XPATH, '//*[text()="请选择来源仓库"]').click()
    time.sleep(3)
    driver.find_element(By.XPATH, '//li[text()="永春库"]').click()
    # 请选择目标仓库
    driver.find_element(By.XPATH, '//*[text()="请选择目标仓库"]').click()
    time.sleep(3)
    driver.find_element(By.XPATH, '(//li[text()="西湖库"])[2]').click()
    #添 加
    driver.find_element(By.XPATH, '//*[text()="保 存"]/..').click()
    time.sleep(2)
    num = driver.find_element(By.XPATH,'//div[text()="移库单号"]/following-sibling::div[1]').text
    driver.find_element(By.XPATH,'//button[@aria-label="Close"]').click()
   #搜索单号
    driver.find_element(By.XPATH,'//input[@placeholder="请搜索移库单号/物料名称/物料编码"]').send_keys(num)
    driver.find_element(By.XPATH,'//*[text()="搜 索"]/..').click()
    time.sleep(3)
    #删除单号
    driver.find_element(By.XPATH, '//*[text()="操作"]/..').click()
    driver.find_element(By.XPATH, '//*[text()="删除"]/..').click()
    driver.find_element(By.XPATH, '//*[text()="确 定"]/..').click()

if __name__ == '__main__':
    login()
>>>>>>> ce159ad8f2d84d52171c22e2deb98eae0a03fe88
    time.sleep(5)